package fileexplorer.view;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import javax.swing.*;
import java.awt.event.ActionEvent;
import java.awt.event.KeyEvent;

/**
 * Created with IntelliJ IDEA.
 * User: rejeev
 * Date: 4/30/13
 * Time: 9:49 PM
 * To change this template use File | Settings | File Templates.
 */
public class ExplorerMenuBar extends JMenuBar {
    private static final Logger LOGGER = LoggerFactory.getLogger(ExplorerMenuBar.class);

    public ExplorerMenuBar(){
        super();
        initialize();
    }

    private void initialize(){
        JMenu menu1 = new JMenu("Favourites");
        menu1.setMnemonic(KeyEvent.VK_F);
        this.add(menu1);
        JMenuItem item1 = new JMenuItem("C drive");
        item1.setMnemonic(KeyEvent.VK_C);
        item1.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_1, ActionEvent.ALT_MASK | ActionEvent.CTRL_MASK));
        menu1.add(item1);
        JMenuItem item2 = new JMenuItem("home");
        item2.setMnemonic(KeyEvent.VK_H);
        item2.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_2, ActionEvent.ALT_MASK | ActionEvent.CTRL_MASK));
        menu1.add(item2);
    }
}
